package com.wenchao.quickstart.utils;

import org.apaches.commons.codec.digest.DigestUtils;


public class SHA256Utils {

    public SHA256Utils() {
    }

    public static String sha256Hex(String str) {
        if (null == str) {
            return null;
        }
        return DigestUtils.sha256Hex(str);
    }

    public static String sha1Hex(String str) {
        if (null == str) {
            return null;
        }
        return DigestUtils.sha1Hex(str);
    }

    public static void main(String[] args) {
        System.out.println(sha1Hex("123456"));
    }
}